<template>
    <div class="search-result">
        <div class="text">搜索结果</div>
        <el-card class="result">
            <ul>
                <li v-for="goods in goodsList"><GoodsItem :goods="goods" /></li>
            </ul>
        </el-card>
    </div>
</template>

<script setup>
import { searchStore } from '@/stores/search'
import { computed } from 'vue'
const useSearchStore = searchStore()
let goodsList = computed(() => useSearchStore.goodsList)
</script>

<style lang="scss" scoped>
.search-result {
    height: auto;
    width: 90%;
    margin-bottom: 10px;
    .text {
        width: 100%;
        text-align: center;
        margin: 10px 0 10px 0;
        font-size: 20px;
    }
    ul {
        display: flex;
    }
}
</style>
